home *** CD-ROM | disk | FTP | other *** search
/ Visual Cafe 3 / Visual Cafe 3.ISO / Vcafe / Source.bin / AlignStyle.java < prev    next >
Text File  |  1998-08-21  |  2KB  |  62 lines

  1. package symantec.itools.awt;
  2.  
  3. import java.beans.PropertyVetoException;
  4.  
  5. //     05/31/97    LAB Updated to Java 1.1
  6.  
  7. /**
  8.  * AlignStyle is an interface for components with labels that can be
  9.  * aligned left, centered, or right.
  10.  * @author Symantec
  11.  */
  12. public interface AlignStyle
  13. {
  14.     //--------------------------------------------------
  15.     // constants
  16.     //--------------------------------------------------
  17.  
  18.     /**
  19.      * Defines the "left" label text alignment style.
  20.      */
  21.     public static final int ALIGN_LEFT = 0;
  22.  
  23.     /**
  24.      * Defines the "center" label text alignment style.
  25.      */
  26.     public static final int ALIGN_CENTERED = 1;
  27.  
  28.     /**
  29.      * Defines the "right" label text alignment style.
  30.      */
  31.     public static final int ALIGN_RIGHT = 2;
  32.  
  33.  
  34.     //--------------------------------------------------
  35.     // methods
  36.     //--------------------------------------------------
  37.  
  38.     /**
  39.      * Sets the new label alignment style.
  40.      * @param style the new alignment style, one of ALIGN_LEFT,
  41.      * ALIGN_CENTERED, or ALIGN_RIGHT
  42.      * @exception PropertyVetoException
  43.      * if the specified property value is unacceptable
  44.      * @see #getAlignStyle
  45.      * @see #ALIGN_LEFT
  46.      * @see #ALIGN_CENTERED
  47.      * @see #ALIGN_RIGHT
  48.      */
  49.     public void setAlignStyle(int style) throws PropertyVetoException;
  50.  
  51.     /**
  52.      * Gets the current label alignment style.
  53.      * @return the current alignment style, one of ALIGN_LEFT,
  54.      * ALIGN_CENTERED, or ALIGN_RIGHT
  55.      * @see #setAlignStyle
  56.      * @see #ALIGN_LEFT
  57.      * @see #ALIGN_CENTERED
  58.      * @see #ALIGN_RIGHT
  59.      */
  60.     public int getAlignStyle();
  61. }
  62.